{% extends 'base.html' %}

{% block title %}新建信息{% endblock %}

{% block content %}
<div class="container mt-4">
    <h4 class="mb-4">新建信息</h4>
    <form method="POST" action="/save_info">
        <div class="mb-3">
            <label class="form-label">标题</label>
            <input type="text" class="form-control" name="title" required>
        </div>
        <div class="mb-3">
            <label class="form-label">平台</label>
            <select class="form-select" name="platform_id">
                {% for platform in platforms %}
                <option value="{{ platform.id }}">{{ platform.name }}</option>
                {% endfor %}
            </select>
        </div>
        <div class="mb-3">
            <label class="form-label">风格</label>
            <select class="form-select" name="style_id">
                {% for style in styles %}
                <option value="{{ style.id }}">{{ style.name }}</option>
                {% endfor %}
            </select>
        </div>
        <div class="mb-3">
            <label class="form-label">状态</label>
            <select class="form-select" name="status_id">
                {% for status in statuses %}
                <option value="{{ status.id }}">{{ status.name }}</option>
                {% endfor %}
            </select>
        </div>
        <button type="submit" class="btn btn-primary">保存</button>
    </form>
</div>
{% endblock %}